 
 int Count_Digit (  int N,  int D )
{ int i,m,sum=0;
  do
  {
     m=N%10;
     if(m<0)  m=-m;
     if(m==D)
    sum++;    
  N=N/10;
  }while(N);
  return sum;
}